<?php
$arraycatnews = getArray('xteam_category','status=1 AND parent_id=1');
if(!empty($arraycatnews)){
	foreach($arraycatnews as $item){
		$keys = $item['id'].',';
	}
	$keys = substr($keys,0,-1);
	$arrayNews = getArray('xteam_content','status=1 AND parent_id IN ('.$keys.')','3','sort,date_added DESC');
	if(!empty($arrayNews)){
		foreach($arrayNews as $itemnews){?>
<div class="page-item">
    <div class="page-item-content"> 
        <a href="<?=$curHost.utf8_to_ascii($newscatali[$itemnews['parent_id']]!=''?$newscatali[$itemnews['parent_id']]:$newscatname[$itemnews['parent_id']])?>/<?=utf8_to_ascii($itemnews['seo_key']!=''?$itemnews['seo_key']:$itemnews['name'])?>/3/<?=$itemnews['id']?>.html">
        	<img alt="<?=$itemnews['name']?>" class="postimg wp-post-image" src="<?=$curHost.$itemnews['image_thumbs']?>">
        </a>
                
        <h3 class="page-item-title">
        	<a title="<?=$itemnews['name']?>" rel="bookmark" href="<?=$curHost.utf8_to_ascii($newscatali[$itemnews['parent_id']]!=''?$newscatali[$itemnews['parent_id']]:$newscatname[$itemnews['parent_id']])?>/<?=utf8_to_ascii($itemnews['seo_key']!=''?$itemnews['seo_key']:$itemnews['name'])?>/3/<?=$itemnews['id']?>.html">
				<?=$itemnews['name']?>
            </a>
        </h3>
        <p>
        	<?=$itemnews['description']?>
        </p>
    </div>
</div>
        
        <?php
		}
	}
}
?>